﻿using DFGK_WMS.Model.Models;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace DFGK.IService
{
    public interface IAreaService
    {
        /// <summary>
        /// 添加库区
        /// </summary>
        /// <param name="obj"></param>
        /// <returns></returns>
        bool AddArea(Area obj, out string message);

        /// <summary>
        /// 库区显示
        /// </summary>
        /// <param name="kname"></param>
        /// <param name="kid"></param>
        /// <param name="pageIndex"></param>
        /// <param name="pageSize"></param>
        /// <param name="totalCount"></param>
        /// <returns></returns>
        List<Area> GetAreanList(string? kname, long wid, int pageIndex, int pageSize, out int totalCount);
        /// <summary>
        /// 删除库区
        /// </summary>
        /// <param name="uid"></param>
        /// <returns></returns>
        bool DelArea(long id);
        /// <summary>
        /// 修改库区信息
        /// </summary>
        /// <param name="u"></param>
        /// <returns></returns>
        bool UpdateArea(Area u, out string message);
        /// <summary>
        /// 根据id获取数据
        /// </summary>
        /// <param name="id"></param>
        /// <returns></returns>
        Area? GetAreaById(long id);

        /// <summary>
        /// 根据库房Id获取库区
        /// </summary>
        /// <param name="wid"></param>
        /// <returns></returns>
        List<Area> GetWhIdAreaList(long wid);
    }
}
